﻿Public Class frmCancelar
    Dim formAusar As UserControl

    Private Sub frmCancelar_Load(sender As Object, e As EventArgs) Handles MyBase.Load

    End Sub

    Public Sub agregarLabels(pnombre As String, ptitulo As String, form As UserControl)
        txtNombre.Text = pnombre
        formAusar = form
        Label3.Text = ptitulo
    End Sub


    Public Sub btnAceptar_Click(sender As Object, e As EventArgs) Handles btnAceptar.Click
        Me.Hide()
        frmTransparente.Close()
        frmSecundario.Close()
    End Sub

    Public Sub btnCancelar_Click(sender As Object, e As EventArgs) Handles btnCancelar.Click

        For Each x As Control In Me.Parent.Controls.OfType(Of UserControl)()
            x.Visible = True
            'formAusar.Visible = True
        Next
        Me.Visible = False
        frmSecundario.Width = Screen.PrimaryScreen.WorkingArea.Width
        frmSecundario.Height = Screen.PrimaryScreen.WorkingArea.Height - Screen.PrimaryScreen.WorkingArea.Height * (30 / 100)
        frmSecundario.Location = New Point(Screen.PrimaryScreen.WorkingArea.X, Screen.PrimaryScreen.WorkingArea.Height * (15 / 100))
    End Sub
End Class
